﻿<%@ Page Language="C#" AutoEventWireup="true" MasterPageFile="~/Template/MasterPage.master"
    CodeFile="Default.aspx.cs" Inherits="_Default" %>

<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" runat="Server">
    <h1>General Information</h1>
    <aspnet:TabStrip ID="tsGenInfo" TargetID="mpGenInfo" runat="server">
      <aspnet:Tab Text="Overview" />
      <aspnet:Tab Text="Tested Environments" />
      <aspnet:Tab Text="Release Notes" />
      <aspnet:Tab Text="Acknowledgements" />
    </aspnet:TabStrip>
    <aspnet:MultiPage ID="mpGenInfo" runat="server">
        <aspnet:PageView ID="pv1" runat="server">
            <p>The purpose of this project is twofold. To learn about <a target="_blank" href="http://www.hibernate.org/343.html">NHibernate</a> and how to use
               it in a real-world application and to create ASP.NET custom providers for Membership
               and Role management that support a single pool of users that can be associated with
               multiple applications, not just one. One of the defficiencies I see with the current
               ASP.NET implementation is that it assumes that there will only be a need to manage
               a user base for a single web application. So, the desire is to create additional controls
               that will support this level of management for more complex web application implementations.</p>
            <p>A secondary goal is to ensure that any implementation will nicely integrate with the <a target="_blank"
               href="http://localhost:1011/asp.netwebadminfiles/default.aspx?applicationPhysicalPath=<%= Request.PhysicalApplicationPath %>&applicationUrl=<%= Request.ApplicationPath %>">
               ASP.NET Web Site Administration Tool</a>.</p>
            <p>This sample solution is comprised of 2 projects: <i>ASP.NETWebAdminFiles</i> and <i>NHibernateProviderTest</i>. Two other projects, <i>NHibernateProvider</i> and <i>NHibernateProviderDatabase</i>, are also available but excluded in this solution. The bulk of what you
               may be interested in is in the <i>NHibernateProvider</i> project (use other solution for this). Nevertheless, a brief description of all projects follows:</p>

            <h4>ASP.NETWebAdminFiles</h4>
            <p>Import of an existing web project. This is simply a reference to the web admin files that are already installed
               with your Microsoft.NET v2.0 configuration. The reference is to <font class="code">C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\ASP.NETWebAdminFiles</font>.
               I have included the ASP.NETWebAdminFiles web application project in the solution simply to allow
               me to fix the port number so I can easily reference it from this application. I was not able
               to find another way to allow me to reference it since Visual Studio always assigns a dynamic
               port whenever the <i>ASP.NET Configuration</i> is launched. The ASP.NETWebAdminFiles is
               the source code for the ASP.NET Web Site Administration Tool.</p>
               
            <h4>NHibernateProviderTest</h4>
            <p>Web application used to test some of the basic <font class="dlgname">Login</font>
               controls functionality in a debug environment. The bulk of the testing happens by using
               the <i>ASP.NET Web Site Administration Tool</i>. This web application has the example configuration
               used for NHibernate and the respective providers, complete with sample connection strings for
               <b>Microsoft Access 2000/2003</b>, <b>Microsoft SQL 2000/2005/SQLEXPRESS</b>, <b>MySQL 5.0</b>,
               and <b>Oracle 10g</b>.</p>
            <p>This project also contains sample databases in the <font class="code">App_Data</font> folder for
               <b>Microsoft Access 2000/2003</b> and <b>Microsoft SQL (SQLEXPRESS)</b>. I also created a database
               for <b>Microsoft Access 2007</b> but I have yet to figure out how to make it work.</p>
            <p>The test application enables security over the <font class="dlgname">Change Password</font> and
               <font class="dlgname">Role Tester</font> pages. That means you will have to first authenticate.
               You can use the <font class="dlgname">Create User</font> page to add yourself a new account and play
               with the application.</p>
            <p>Because the intent is to use the web site management capabilities built in .NET 2.0, I would suggest
               that you do any final checks against <i>ASP.NET Web Site Administration Tool</i>.</p>
            <p>In addition to allowing for the testing of the NHibernateProvider implemenation, this web application
               is a good example of the following ASP.NET features:</p>
            <ul>
                <li>How to use of Themes and Skins in your web applicaton. These are new features in ASP.NET 2.0.
                    You will see how clean your <font class="code">.aspx</font> pages can become when using these
                    features.</li>
                <li>How to secure your web application and use the built in site navigation features.</li>
            </ul>

            <h4>NHibernateProvider</h4>
            <p>The core of the provider logic. This is the project that
               holds the details of the Membership and Role providers. Any NHibernate logic also resides
               in this project, including the mapping files.</p>
               
            <h4>NHibernateProviderDatabase</h4>
            <p>The container for the data model used with this provider implementation. It has a
               <i>Visio for Enterprise Architects</i> database model and some DDL files for <b>Microsoft SQL Server 2000/2005/SQLEXPRESS</b>,
               <b>MySQL 5.0</b>, and <b>Oracle 10g</b>.</p>
        </aspnet:PageView>
        <aspnet:PageView>
            <p>The NHibernateProvider implemetation has been tested using the following NHibernate releases:</p>
            <ul>
              <li><b>NHibernate v1.0.3</b></li>
              <li><b>NHibernate v1.0.4</b></li>
              <li><b>NHibernate 1.2.0 Beta 2</b></li>
              <li><b>NHibernate 1.2.0 Beta 3</b></li>
              <li><b>NHibernate 1.2.0 CR1</b></li>
            </ul>
            <p>You are currently running with the following assemblies:</p>
            <ul>
                <li><b><%= NHibernateProvider.Util.AssemblyUtil.GetAssemblyFullName("NHibernate") %></b></li>
                <li><b><%= NHibernateProvider.Util.AssemblyUtil.GetAssemblyFullName("NHibernateProvider") %></b></li>
            </ul>
            <p>The NHibernateProvider implementation has been tested on the following databases:</p>
            <ul>
                <li><b>Microsoft Access 2000/2003</b></li>
                <li><b>Microsoft SQL 2000/2005/SQLEXPRESS</b></li>
                <li><b>MySQL 5.0</b></li>
                <li><b>Oracle 10g</b></li>
            </ul>
        </aspnet:PageView>
        <aspnet:PageView>
            <h2>Latest Release</h2>
            <p>For the latest release of NHibernateProvider visit the <a target="_blank" href="http://www.codeplex.com/nhibernateprovider">NHibernateProvider Home</a> at GotDotNet.</p>
            <h2>Known Issues</h2>
            <ul>
                <li>None to report at this time.</li>
            </ul>
            <h2>History</h2>
            <h3>RTM Build 1.0.0.0</h3><h4>(Released: 2/23/2007)</h4>
            <ul>
              <li>Removed sample Web Application. I will add it back later once I get more organized.</li>
              <li>Changed structure to add to Team Foundation Server Source Control at CodePlex.</li>
              <li>Added source code reference help in the following formats: <b>HtmlHelp 1.x</b>, <b>HtmlHelp 2.x</b>, and <b>Website</b>. The latter is just a plain HTML site to view the source code reference.</li>
              <li>Moved project to CodePlex.</li>
            </ul>

            <h3>Beta Build 0.4.0.0</h3><h4>(Released: 12/22/2006)</h4>
            <ul>
                <li>Added support for <b>MySQL 5.0</b> database.</li>
            </ul>

            <h3>Beta Build 0.3.0.0</h3><h4>(Released: 12/12/2006)</h4>
            <ul>
                <li>Added support for <b>Microsoft Access 2000/2003</b> database.</li>
                <li>Added a strong name key file to sign the NHibernateProvider assembly.</li>
                <li>Updated the implementation to support the separation of single- vs. multiple- web application models. The NHibernateProvider logic must
                    support the single-web application model because of the nature of the ASP.NET Membership/Role Provider design. Previous implementations
                    of NHibernateProvider did not make this distinction and would therefore perform operations as though a single web application was always
                    being managed. Because the NHibernateProvider implementation will support its own management controls and the multi-web application model,
                    the implementation needed to clearly isolate both. From a usage perspective, the logic is unmodified from previous versions. Underneath,
                    the implementation uses specific queries to perform the logic assuming a single web application, just like the ASP.NET design calls for.
               </li>
            </ul>
            <p>Please note that support of <b>Microsoft Access 2000/2003</b> is only available when using <b>NHibernate v1.0.3</b> together with the
               <b>NHibernate.JerDriver v1.1</b> that is part of the <b>NHibernateContrib v1.0.3</b> project. The associated download is configured to
               use the included Microsoft Access database.</p>

            <h3>Alpha Build 0.2.0.0</h3><h4>(Released: 12/06/2006)</h4>
            <p>This version is fully functional and following some user testing it should be in Beta and then Release very fast. I would like some feedback on the use of
               NHibernate. If there are areas where the use of it can be optimized please let me know.</p>
            <ul>
                <li>Implemented logic to remove references when <font class="code">User</font> or <font class="code">Role</font> instances are removed.</li>
                <li>Completed logic for tracking login failed attempts.</li>
                <li>Completed testing within <a target="_blank" href="http://localhost:1011/asp.netwebadminfiles/default.aspx?applicationPhysicalPath=<%= Request.PhysicalApplicationPath %>&applicationUrl=<%= Request.ApplicationPath %>">
                    ASP.NET Web Site Administration Tool</a>. Now everything works fine even through the <a target="_blank" href="http://localhost:1011/asp.netwebadminfiles/security/wizard/wizard.aspx">Security Setup Wizard</a>.
                </li>
                <li>Fixed missing page reference to <font class="dlgname">Create User</font> page from <font class="dlgname">Login</font> page.</li>
                <li>Modified <font class="code">User</font> class and <font class="code">MembershipUser</font> table definition to fix name inconsistencies
                    around Password Failure. This changes affect the mapping file <font class="code">User.hbm.xml</font>. Attached database and DDL scripts
                    have also been updated.
                </li>
                <li>Added sample <font class="code">machineKey</font> entry in <font class="code">Web.config</font> to show how you can override the default used
                    by the NHibernateProvider implementation. If you don't specify a machine key, the provider will create a new machine key every time it is
                    initialized (during application start) and use it for the duration of its session. The details are stored with the affected data so that
                    subsequent checks succeed. Use this override when you are attempting to perform Single-Sign-On accross a set of ASP.NET web applications.
                </li>
            </ul>

            <h3>Alpha Build 0.1.0.0</h3><h4>(Released: 12/05/2006)</h4>
            <ul>
                <li>First public release with functional implementations for ASP.NET Membership and Role providers using <b>NHibernate v1.0.3</b> and
                    <b>NHibernate 1.2 Beta 2</b>, with support for <b>Microsoft SQL 2000/2005/SQLEXPRESS</b> and <b>Oracle 10g</b>.
                </li>
            </ul>
        </aspnet:PageView>
        <aspnet:PageView>
            <p>I would like to acknowledge the following people for their contribution (direct or indirect) to help me solve different issues with this implementation.</p>
            <ul>
                <li><b>ben-rush</b> for his sample OracleProviders code in VB.NET. This code can be found at <a target="_blank" href="http://www.ben-rush.net/source/OracleProviders/">his site</a>.</li>
                <li><b>sergey</b> for his tip on using <font class="code">IUserType</font> to implement a user type to handle Oracle-specific
                    use of <font class="code">CHAR(1)</font> to represent <font class="code">boolean</font> properties. (See forum thread
                    <a target="_blank" href="http://forum.hibernate.org/viewtopic.php?t=967895">here</a>.)
                </li>
                <li><b>bosh</b> for his tip on the <font class="code">lazy="false"</font> fix for my issue with NHibernate
                    1.2 Beta 2 and proxy implementation. (See forum thread <a target="_blank" href="http://forum.hibernate.org/viewtopic.php?t=968088">here</a>.)
                </li>
            </ul>
        </aspnet:PageView>
    </aspnet:MultiPage>
</asp:Content>
